import request from '@/utils/request'

// 查询推荐客户列表
export function listScore(query) {
  return request({
    url: '/prod-api/recommend/customer/listOther',
    method: 'get',
    params: query
  })
}

// 查询推荐客户列表
export function listSelf(query) {
  return request({
    url: '/prod-api/recommend/customer/listSelf',
    method: 'get',
    params: query
  })
}


// 查询推荐客户详细列表
// export function listDetail(query) {
//   return request({
//     url: '/prod-api/recommend/customer/listDetail',
//     method: 'get',
//     params: query
//   })
// }


// 修改推荐客户状态
export function updateScoreStatus(recommendId, acceptStatus){
  const data = {
    recommendId,
    acceptStatus
  }
  return request({
    url: '/prod-api/recommend/customer/updateCustomerStatus',
    method: 'put',
    data: data
  })
}



// 新增推荐客户
export function addScore(data) {
  return request({
    url: '/prod-api/recommend/customer/add',
    method: 'post',
    data: data
  })
}

// 修改推荐客户
export function updateScore(data) {
  return request({
    url: '/prod-api/recommend/customer/updateCustomer',
    method: 'put',
    data: data
  })
}

// 删除推荐客户
export function delScore(recommendId) {
  return request({
    url: '/prod-api/recommend/customer/' + recommendId,
    method: 'delete'
  })
}
